package com.mbc.web.common.client.ui.control;

import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.user.client.ui.HasHorizontalAlignment.AutoHorizontalAlignmentConstant;
import com.google.gwt.user.client.ui.HasHorizontalAlignment.HorizontalAlignmentConstant;
import com.google.gwt.user.client.ui.HasVerticalAlignment.VerticalAlignmentConstant;

public class GridColumn
{
	protected static final byte column_default = 0;
	protected static final byte column_TextBox = 1;
	protected static final byte column_ComboBox = 2;
	protected static final byte column_CheckBox = 3;
	protected static final byte column_Button = 4;
	protected static final byte column_image = 5;
	protected static final byte column_auto_number = 6;
	protected static final byte column_label_column = 7;
	protected static final byte column_lookup_column = 8;
	protected static final byte column_radio_button = 9;
	protected static final byte column_datebox = 10;
	
	public HorizontalAlignmentConstant horizontalAlignment;
	public VerticalAlignmentConstant verticalAlignment;
	public AutoHorizontalAlignmentConstant autoHorizontalAlignment;
	public String width = "";
	public String height = "";
	public String header = "";
	public String styleName = "";
	public int index = 0;
	private boolean isSortable = false;
	private ClickHandler headerClickhandler;
	protected byte columnType;
	
	public GridColumn()
	{
		columnType = GridColumn.column_default;
	}

	public boolean isSortable() {
		return isSortable;
	}

	public void setSortable(boolean isSortable, ClickHandler headerClickHandler) {
		this.isSortable = isSortable;
		this.headerClickhandler = headerClickHandler;
	}

	public ClickHandler getHeaderClickhandler() {
		return headerClickhandler;
	}
}
